package com.tianpengtech.admin.opertion;
import java.util.List;
import java.util.Map;

import com.jfinal.plugin.activerecord.Model;
import com.tianpengtech.common.exception.ValidateException;
import com.tianpengtech.admin.AbstractAdmin;
import com.tianpengtech.admin.IAdminLogRecord;
import com.tianpengtech.common.model.opertion.Opertion;
import com.tianpengtech.common.search.QueryConstructor;

public class OpertionAdminServiceImpl extends AbstractAdmin implements IAdminLogRecord{

	@Override
	public void beforeAdd(Model<?> model) throws ValidateException {

	}

	@Override
	public void beforeQueryById(Model<?> model, int id) {

	}

	@Override
	public void beforeUpdate(Model<?> model) throws ValidateException {

	}

	@Override
	public void beforeDelete(Model<?> model) {

	}

	@Override
	public void builderSQLExpected(Model< ? > model,
			QueryConstructor queryConstruct, Map< String, Object > params) {

	}

	@Override
	public String tableName() {
		return Opertion.dao.tableName();
	}

	@Override
	public List<Opertion> queryOperationsByObjId(int obj_id, int opt_type) {
		return new OperationDao().queryOperationsByObjId(obj_id, opt_type);
	}

}